<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN"><HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=ISO-8859-1">
<META HTTP-EQUIV="Content-Style-Type" CONTENT="text/css">

<LINK REL="STYLESHEET" HREF="../book.css" CHARSET="ISO-8859-1" TYPE="text/css">
<title>Versioning</title>

</HEAD>
<BODY BGCOLOR="#ffffff">
<H1 CLASS="Head">
Versioning</H1>
<P CLASS="Intro">
Resources are versioned in order to capture a
snapshot of the current state of the resources at one specific point in time.&nbsp;&nbsp;
<DIV CLASS="Topic">
<h2>
Base Versions</h2>
<P CLASS="Para">
A base version of a resource represents the resource
version that was last added to the workspace.&nbsp;</P>
<P CLASS="Para">Enabling the <i>Show Version Info...</i> menu item in the Navigator
or Packages view displays the base version of each released file.</P>
</DIV>
<DIV CLASS="Topic">
<h2>
Versionable Resources&nbsp;</h2>
<P CLASS="Para">
Resources other than projects (i.e. files and
folders) cannot be explicitly versioned.&nbsp; However during synchronization these types
of resources are implicitly versioned when they are released to the stream.</P>
</DIV>
<P CLASS="Intro">Versioning a project save the line-up of all resource versions in the project. The difference between versioning from the workspace or from the
stream is in deciding which child resource versions should be part of the project version.
<h3>
Version from Workspace</h3>
<P CLASS="Para">
When versioning a project from the workspace, the <i> base version</i> of the resources in the workspace are captured
as part of the project version.&nbsp; This is the preferred method of versioning a project because you know exactly
which resource versions will be in the project version.&nbsp;<br>
<br>
This operation is allowed if you have outgoing changes or unreleased changes. Unreleased changes
are simply ignored and resources with outgoing changes can still have their base versions
be part of the project version.&nbsp; Versioning a project with unreleased or outgoing changes is
handy if you have to split the project at the point where you started making changes to the resources and release
the resources to another stream.</P>
<h3>
Version from Stream</h3>
<P CLASS="Para">
When versioning from the stream you are versioning what ever the latest
resource versions are in the stream at that moment in time.&nbsp; You should not
version your projects from the stream if you don't know what is released in the stream. For this reason, versioning from the workspace is often preferable.<br>
<br>
Take for example the case where you want to version a project in a stream even if you&nbsp;don't have it loaded.
You are merging changes made on streamB into&nbsp; streamA and your project is shared with the streamA, and not streamB.&nbsp; To version the project&nbsp;in
streamB with a version name like "merged_on_may_28", you would version the stream contents,
not the contents of the workbench.&nbsp; Of course, since some repositories do not support locking of streams, you
need to ensure that nobody else releases into streamB concurrently. You can do this
by using social protocols.&nbsp;</P>
<DIV CLASS="Topic">
<h2>
Version Selected Resources Dialog</h2>
<P CLASS="Para">
In this dialog, you can choose the version labels for the projects you are versioning.&nbsp;
You can only choose the version label for the project level; resources are
versioned when released.&nbsp;&nbsp;</P>
<P CLASS="Para">
Here is what the Version Selected Resources dialog looks like:</P>
<P CLASS="Para">
<img align="texttop" border="0" src="../images/Image259_version_dialog.jpg" width="397" height="178"></P>
<DIV CLASS="XRefList">
<LI CLASS="Item">
See CVS Version Label Syntax Rules above.</LI>
</DIV>
<h3>
Version Label Options</h3>
<h4>Automatic</h4>
<p>Versions each project with an automatically generated label.&nbsp; This is
the default option.</p>
<h4>One Name</h4>
<p>Versions each project with the label specified in the text area.</p>
<h4>Name Each</h4>
<p> You
can specify the name of each project you are versioning.</p>
<p>Here is the dialog you will be presented with for each project when choosing
this versioning option:</p>
<p><b>Details Button</b></p>
<p>The details button shows all existing versions.</p>
<p><img align="texttop" border="0" src="../images/Image260_version_each.jpg" width="343" height="226"></p>
<DIV CLASS="Subtopic">
<h3>
CVS Version Label Syntax Rules</h3>
<P CLASS="Para">
Version labels must meet the following criteria:</P>
<UL CLASS="UnorderedList">
<LI CLASS="Item">
Labels must begin with a letter.</LI>
<LI CLASS="Item">
They must contain only letters, numbers, dashes, and underscores.</LI>
<LI CLASS="Item">
No special characters are allowed.</LI>
</UL>
<DIV CLASS="Note">
<P CLASS="Para">
Note:	Periods are not allowed in CVS version labels. It is suggested that you use dashes or underscores instead.</P>
</DIV>
</DIV>
<DIV CLASS="Subtopic">
<h3>
Automatic Version Labeling</h3>
<P CLASS="Para">
If you select Automatic version labeling format, the following &quot;guessing&quot; schema is used to assign version labels.</P>
<UL CLASS="UnorderedList">
<LI CLASS="Item">
If a project has no previous version label, then the default version name is used.&nbsp;
You can indicate the desired default version name (Window &gt; Preferences &gt;
Team).</LI>
<LI CLASS="Item">
If a project already has a previous version label:</LI>
<UL CLASS="UnorderedList">
<LI CLASS="Item">
The previous version label is separated into a text prefix and a numerical suffix, where the suffix is any trailing digits on the previous version name. If the previous version has no trailing digits, then the suffix is 0.</LI>
<LI CLASS="Item">
The first guess at a version label is the text prefix combined with the incremented suffix (i.e., suffix + 1).</LI>
<LI CLASS="Item">
If the guess matches an existing version label for that project, the suffix is
incremented again to produce another guess.&nbsp; This continues until a guess
is found that does not match any previous version.</LI>
</UL>
</UL>
</DIV>
</DIV>
<P>&nbsp;<br>
<img src = ../ngibmcpy.gif width="195" height="12">
</P>


</BODY>
</HTML>
